﻿using System;
using System.Collections.Generic;
using System.Text;

namespace FDStudio.Core.Entities.Factories
{
    /*
     CreatedOn: 2018-01-25
     CreatedBy: Jackie Lee(天宇遊龍)
     */
    /// <summary>
    /// api请求结果
    /// </summary>
    public interface IApiResultFactory : IComm
    {
        IApiResult Create();

        IApiResult Success(int code, string message);

        IApiResult<T> Success<T>(int code, string message, T result);

        IApiResult Falure(int code, string message);

        IApiResult<T> Falure<T>(int code, string message);

        IApiResult Error(int code, Exception ex);

        IApiResult<T> Error<T>(int code, Exception ex);
    }
}
